import request from '@/utils/request'

// 根据反馈ID查询详细信息
export const getGridWorker = (id) => {
  return request.get(`/nepm/feedback/queryone?id=${id}`);
};
// https://m1.apifoxmock.com/m1/6520161-6220835-default/nepm/feedback/queryone

//根据省市获取网格员
export const getGridWorkerByCity = (province, city) => {
  return request.get(`/nepm/worker/list?province=${province}&city=${city}`);
};
//http://127.0.0.1:4523/m1/6520161-6220835-default/nepm/worker/list

//获取所有省份
export const getProv = ()=>{
  return request.get('/nepm/provinces/list');
}
//根据省，获取有网格员活动的市
export const getCityByProv = (province)=>{
  return request.get(`/nepm/provinces/cityWithWorker?provinceName=${province}`);
}
// https://m1.apifoxmock.com/m1/6520161-6220835-default/nepm/provinces/cityWithWorker
//指派反馈任务
export const assignTask = (id, assignWorkerCode) => {
  return request.put('/nepm/feedback/assign', {
    id,
    assignWorkerCode
  });
};
// https://m1.apifoxmock.com/m1/6520161-6220835-default/nepm/feedback/assign